package com.touzhijia.authority.model;

import lombok.Data;
import org.springframework.ldap.odm.annotations.Attribute;
import org.springframework.ldap.odm.annotations.Entry;
import org.springframework.ldap.odm.annotations.Id;

import javax.naming.Name;
import java.io.Serializable;

/**
 * 作者： lzw<br/>
 * 创建时间：2018-03-13 18:38 <br/>
 */
@Data
@Entry(base = "OU=TouZhiJia,DC=touzhijia,DC=net", objectClasses = {"user", "person", "organizationalPerson"})
public class LdapUser implements Serializable {

    @Id
    private Name id;

    @Attribute(name = "samAccountName")
    private String username;

    @Attribute(name = "name")
    private String nickname;

    @Attribute(name = "telephoneNumber")
    private String telephone;

    @Attribute(name = "mail")
    private String email;

    @Attribute(name = "memberOf")
    private String memberOf;
}
